<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:a4j="http://richfaces.org/a4j"
	xmlns:rich="http://richfaces.org/rich"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:c="http://java.sun.com/jstl/core"
    template="../admin/admin-template.xhtml"> 
   <h:outputStylesheet>
        .ecol1 {
        vertical-align: top;
        padding-right: 25px
        }
 
        .ecol2 {
        vertical-align: top;
        border-left: #ACBECE 1px solid;
        padding-left: 10px
        }
 
        .rich-calendar-tool-btn {
        font-family: Arial, Verdana;
        }
    </h:outputStylesheet>
	<ui:define name="title">Добави роля или ранг</ui:define>
	<ui:define name="body">
	<h1>Администрация <span>: Въведете желан ранг</span></h1>
		<p>Обузначените със <span style="color:red;">*</span> полета са задължителни !</p>
	<div id="addRole">
	
	<h:form>
		
		<table>
		<tr>
		<td><span style="color:red;">* </span>Изберете роля</td>
		<td>
		<h:selectOneMenu id="roleselect" requiredMessage=" моля изберете роля"  required="true" value="#{rangActions.status}"  >
			<f:selectItem itemValue="" itemLabel="------"/>
		  	<f:selectItems value="#{rangActions.mRole}" var="br" itemLabel="#{br.roleName}" itemValue="#{br.roleID}" />
		</h:selectOneMenu>
		<h:message style="color:red;" for="roleselect"> </h:message>
		</td>
		</tr>
		<tr>
			<td><span style="color:red;">* </span>Име на ранг</td>
			<td><h:inputText id="rankname" requiredMessage=" въведете име на ранг" required="true" value="#{rangActions.rank.rankName}" />
			<h:message style="color:red;" for="rankname"> </h:message>
			 </td>
		</tr>
			<tr>
			<td><span style="color:red;">* </span>Описание на ранг</td>
			<td><h:inputTextarea id="rankdescr" requiredMessage=" въведете описание на ранг" required="true" value="#{rangActions.rank.description}" />
			<h:message style="color:red;" for="rankdescr"> </h:message>
			 </td>
		</tr>
		
			<tr>
			<td></td>
			<td>
			<h:commandButton styleClass="btnSubmit" style="margin-left: 0px;" action="#{rangActions.save(rangActions.rank,rangActions.status)}" value="Запамети">
    			</h:commandButton>
			</td>
		</tr>
		</table>
	</h:form>
           

 </div>
	</ui:define>
	</ui:composition>

